package com.cardone.platform.usercenter.service;

import java.util.List;
import java.util.Map;
import java.util.UUID;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.NonNull;
import lombok.Setter;

import org.apache.commons.lang3.ArrayUtils;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.transaction.annotation.Transactional;

import com.cardone.common.dto.PaginationDto;
import com.cardone.common.utils.EntityUtils;
import com.cardone.persistent.CommonDtoAttributes;
import com.cardone.platform.usercenter.dao.UsOrgTranslateDao;
import com.cardone.platform.usercenter.dao.UserActivationDao;
import com.cardone.platform.usercenter.dao.UserDao;
import com.cardone.platform.usercenter.dto.UsOrgTranslateDto;
import com.cardone.platform.usercenter.dto.UserActivationDto;
import com.cardone.platform.usercenter.dto.UserDto;

/**
 * 用户服务
 * 
 * @author yaoht
 * 
 */
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public class UserDefaultService implements UserService {
	/**
	 * 用户激活数据持久
	 */
	private UserActivationDao userActivationDao;

	/**
	 * 用户数据持久
	 */
	private UserDao userDao;

	/**
	 * 用户组织调动数据持久
	 */
	private UsOrgTranslateDao usOrgTranslateDao;

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int deleteUserActivationByCode(@NonNull UserActivationDto deleteUserActivation) {
		return this.userActivationDao.deleteByCode(deleteUserActivation, new String[] {});
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int deleteUserActivationByIds(@NonNull UserActivationDto deleteUserActivation) {
		return this.userActivationDao.deleteByIds(deleteUserActivation);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int deleteUserByCode(@NonNull UserDto deleteUser) {
		return this.userDao.deleteByCode(deleteUser, new String[] {});
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int deleteUserByIds(@NonNull UserDto deleteUser) {
		return this.userDao.deleteByIds(deleteUser);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int deleteUsOrgTranslateByCode(@NonNull UsOrgTranslateDto deleteUsOrgTranslate) {
		return this.usOrgTranslateDao.deleteByCode(deleteUsOrgTranslate, new String[] {});
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int deleteUsOrgTranslateByIds(@NonNull UsOrgTranslateDto deleteUsOrgTranslate) {
		return this.usOrgTranslateDao.deleteByIds(deleteUsOrgTranslate);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public List<UserActivationDto> findListUserActivationByCode(@NonNull UserActivationDto findListUserActivation) {
		return this.userActivationDao.findListByCode(UserActivationDto.class, findListUserActivation, new String[] {}, new String[] {});
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public List<UserActivationDto> findListUserActivationByName(@NonNull UserActivationDto findListUserActivation) {
		return this.userActivationDao.findListByName(UserActivationDto.class, findListUserActivation);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public List<UserDto> findListUserByCode(@NonNull UserDto findListUser) {
		return this.userDao.findListByCode(UserDto.class, findListUser, new String[] {}, new String[] {});
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public List<UserDto> findListUserByName(@NonNull UserDto findListUser) {
		return this.userDao.findListByName(UserDto.class, findListUser);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public List<UsOrgTranslateDto> findListUsOrgTranslateByCode(@NonNull UsOrgTranslateDto findListUsOrgTranslate) {
		return this.usOrgTranslateDao.findListByCode(UsOrgTranslateDto.class, findListUsOrgTranslate, new String[] {}, new String[] {});
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public List<UsOrgTranslateDto> findListUsOrgTranslateByName(@NonNull UsOrgTranslateDto findListUsOrgTranslate) {
		return this.usOrgTranslateDao.findListByName(UsOrgTranslateDto.class, findListUsOrgTranslate);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public UserActivationDto findUserActivationByCode(@NonNull UserActivationDto findUserActivation) {
		return this.userActivationDao.findByCode(UserActivationDto.class, findUserActivation, null, CommonDtoAttributes.id.name());
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public UserActivationDto findUserActivationById(@NonNull UserActivationDto findUserActivation) {
		return this.userActivationDao.findByCode(UserActivationDto.class, findUserActivation, null, CommonDtoAttributes.id.name());
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public UserDto findUserByCode(@NonNull UserDto findUser) {
		return this.userDao.findByCode(UserDto.class, findUser, null, CommonDtoAttributes.id.name());
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public UserDto findUserById(@NonNull UserDto findUser) {
		return this.userDao.findByCode(UserDto.class, findUser, null, CommonDtoAttributes.id.name());
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public UsOrgTranslateDto findUsOrgTranslateByCode(@NonNull UsOrgTranslateDto findUsOrgTranslate) {
		return this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, findUsOrgTranslate, null, CommonDtoAttributes.id.name());
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public UsOrgTranslateDto findUsOrgTranslateById(@NonNull UsOrgTranslateDto findUsOrgTranslate) {
		return this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, findUsOrgTranslate, null, CommonDtoAttributes.id.name());
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public PaginationDto<UserActivationDto> paginationUserActivationByCode(@NonNull UserActivationDto paginationUserActivation) {
		return this.userActivationDao.paginationByCode(UserActivationDto.class, paginationUserActivation);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public PaginationDto<Map<String, Object>> paginationUserActivationByName(@NonNull UserActivationDto paginationUserActivation) {
		return this.userActivationDao.paginationByName(paginationUserActivation);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public PaginationDto<UserDto> paginationUserByCode(@NonNull UserDto paginationUser) {
		return this.userDao.paginationByCode(UserDto.class, paginationUser);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public PaginationDto<Map<String, Object>> paginationUserByName(@NonNull UserDto paginationUser) {
		return this.userDao.paginationByName(paginationUser);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public PaginationDto<UsOrgTranslateDto> paginationUsOrgTranslateByCode(@NonNull UsOrgTranslateDto paginationUsOrgTranslate) {
		return this.usOrgTranslateDao.paginationByCode(UsOrgTranslateDto.class, paginationUsOrgTranslate);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public PaginationDto<Map<String, Object>> paginationUsOrgTranslateByName(@NonNull UsOrgTranslateDto paginationUsOrgTranslate) {
		return this.usOrgTranslateDao.paginationByName(paginationUsOrgTranslate);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public Integer readUserActivationByCodeNqId(@NonNull UserActivationDto readUserActivation) {
		return this.userActivationDao.readByCodeNqId(Integer.class, readUserActivation);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public Integer readUserActivationByName(@NonNull UserActivationDto readUserActivation) {
		return this.userActivationDao.readByName(Integer.class, null, readUserActivation);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public Integer readUserByCodeNqId(@NonNull UserDto readUser) {
		return this.userDao.readByCodeNqId(Integer.class, readUser);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public Integer readUserByName(@NonNull UserDto readUser) {
		return this.userDao.readByName(Integer.class, null, readUser);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public Integer readUsOrgTranslateByCodeNqId(@NonNull UsOrgTranslateDto readUsOrgTranslate) {
		return this.usOrgTranslateDao.readByCodeNqId(Integer.class, readUsOrgTranslate);
	}

	@Override
	@Cacheable(value = UserService.BEAN_ID, key = com.cardone.common.cache.Constants.KEY_1)
	public Integer readUsOrgTranslateByName(@NonNull UsOrgTranslateDto readUsOrgTranslate) {
		return this.usOrgTranslateDao.readByName(Integer.class, null, readUsOrgTranslate);
	}

	@Override
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public void reload() {
		this.userDao.reload();

		this.userActivationDao.reload();

		this.usOrgTranslateDao.reload();
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public UserActivationDto saveUserActivationByIdOrCode(@NonNull UserActivationDto saveUserActivation) {
		final String[] whereAndEqProperties = EntityUtils.getWhereProperties(saveUserActivation, CommonDtoAttributes.code.name());

		final UserActivationDto oldUserActivation = this.userActivationDao.findByCode(UserActivationDto.class, saveUserActivation,
		        null, whereAndEqProperties);

		if (oldUserActivation == null) {
			saveUserActivation.setId(UUID.randomUUID().toString());

			this.userActivationDao.insertByCode(saveUserActivation);

			final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(saveUserActivation);

			return this.userActivationDao.findByCode(UserActivationDto.class, saveUserActivation, null, notNullIdProperties);
		}

		final String[] useProperties = EntityUtils.addNotNullTimeSegmentProperties(new String[] { CommonDtoAttributes.parentId.name(),
		        CommonDtoAttributes.typeId.name(), CommonDtoAttributes.code.name(), CommonDtoAttributes.name.name(),
		        CommonDtoAttributes.orderCode.name(), CommonDtoAttributes.value.name(), CommonDtoAttributes.remark.name() },
		        saveUserActivation);

		final String[] updateProperties = com.cardone.common.utils.BeanUtils.diffProperties(saveUserActivation, oldUserActivation,
		        useProperties);

		if (ArrayUtils.isEmpty(updateProperties)) {
			return oldUserActivation;
		}

		final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(oldUserActivation);

		com.cardone.common.utils.BeanUtils.copyProperties(oldUserActivation, saveUserActivation, notNullIdProperties);

		this.userActivationDao.updateByCode(saveUserActivation, updateProperties, notNullIdProperties);

		return this.userActivationDao.findByCode(UserActivationDto.class, oldUserActivation, null, notNullIdProperties);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public UserActivationDto saveUserActivationByName(@NonNull UserActivationDto saveUserActivation) {
		final String[] whereAndEqProperties = EntityUtils.getWhereProperties(saveUserActivation, CommonDtoAttributes.code.name());

		final UserActivationDto oldUserActivation = this.userActivationDao.findByCode(UserActivationDto.class, saveUserActivation,
		        null, whereAndEqProperties);

		if (oldUserActivation == null) {
			saveUserActivation.setId(UUID.randomUUID().toString());

			this.userActivationDao.insertByCode(saveUserActivation);

			final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(saveUserActivation);

			return this.userActivationDao.findByCode(UserActivationDto.class, saveUserActivation, null, notNullIdProperties);
		}

		final String[] useProperties = EntityUtils.addNotNullTimeSegmentProperties(new String[] { CommonDtoAttributes.parentId.name(),
		        CommonDtoAttributes.typeId.name(), CommonDtoAttributes.code.name(), CommonDtoAttributes.name.name(),
		        CommonDtoAttributes.orderCode.name(), CommonDtoAttributes.value.name(), CommonDtoAttributes.remark.name() },
		        saveUserActivation);

		final String[] updateProperties = com.cardone.common.utils.BeanUtils.diffProperties(saveUserActivation, oldUserActivation,
		        useProperties);

		if (ArrayUtils.isEmpty(updateProperties)) {
			return oldUserActivation;
		}

		final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(oldUserActivation);

		com.cardone.common.utils.BeanUtils.copyProperties(oldUserActivation, saveUserActivation, notNullIdProperties);

		this.userActivationDao.updateByCode(saveUserActivation, updateProperties, notNullIdProperties);

		return this.userActivationDao.findByCode(UserActivationDto.class, oldUserActivation, null, notNullIdProperties);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public UserDto saveUserByIdOrCode(@NonNull UserDto saveUser) {
		final String[] whereAndEqProperties = EntityUtils.getWhereProperties(saveUser, CommonDtoAttributes.code.name());

		final UserDto oldUser = this.userDao.findByCode(UserDto.class, saveUser, null, whereAndEqProperties);

		if (oldUser == null) {
			saveUser.setId(UUID.randomUUID().toString());

			this.userDao.insertByCode(saveUser);

			final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(saveUser);

			return this.userDao.findByCode(UserDto.class, saveUser, null, notNullIdProperties);
		}

		final String[] useProperties = EntityUtils.addNotNullTimeSegmentProperties(new String[] { CommonDtoAttributes.parentId.name(),
		        CommonDtoAttributes.typeId.name(), CommonDtoAttributes.code.name(), CommonDtoAttributes.name.name(),
		        CommonDtoAttributes.orderCode.name(), CommonDtoAttributes.value.name(), CommonDtoAttributes.remark.name() }, saveUser);

		final String[] updateProperties = com.cardone.common.utils.BeanUtils.diffProperties(saveUser, oldUser, useProperties);

		if (ArrayUtils.isEmpty(updateProperties)) {
			return oldUser;
		}

		final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(oldUser);

		com.cardone.common.utils.BeanUtils.copyProperties(oldUser, saveUser, notNullIdProperties);

		this.userDao.updateByCode(saveUser, updateProperties, notNullIdProperties);

		return this.userDao.findByCode(UserDto.class, oldUser, null, notNullIdProperties);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public UserDto saveUserByName(@NonNull UserDto saveUser) {
		final String[] whereAndEqProperties = EntityUtils.getWhereProperties(saveUser, CommonDtoAttributes.code.name());

		final UserDto oldUser = this.userDao.findByCode(UserDto.class, saveUser, null, whereAndEqProperties);

		if (oldUser == null) {
			saveUser.setId(UUID.randomUUID().toString());

			this.userDao.insertByCode(saveUser);

			final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(saveUser);

			return this.userDao.findByCode(UserDto.class, saveUser, null, notNullIdProperties);
		}

		final String[] useProperties = EntityUtils.addNotNullTimeSegmentProperties(new String[] { CommonDtoAttributes.parentId.name(),
		        CommonDtoAttributes.typeId.name(), CommonDtoAttributes.code.name(), CommonDtoAttributes.name.name(),
		        CommonDtoAttributes.orderCode.name(), CommonDtoAttributes.value.name(), CommonDtoAttributes.remark.name() }, saveUser);

		final String[] updateProperties = com.cardone.common.utils.BeanUtils.diffProperties(saveUser, oldUser, useProperties);

		if (ArrayUtils.isEmpty(updateProperties)) {
			return oldUser;
		}

		final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(oldUser);

		com.cardone.common.utils.BeanUtils.copyProperties(oldUser, saveUser, notNullIdProperties);

		this.userDao.updateByCode(saveUser, updateProperties, notNullIdProperties);

		return this.userDao.findByCode(UserDto.class, oldUser, null, notNullIdProperties);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public UsOrgTranslateDto saveUsOrgTranslateByIdOrCode(@NonNull UsOrgTranslateDto saveUsOrgTranslate) {
		final String[] whereAndEqProperties = EntityUtils.getWhereProperties(saveUsOrgTranslate, CommonDtoAttributes.code.name());

		final UsOrgTranslateDto oldUsOrgTranslate = this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, saveUsOrgTranslate,
		        null, whereAndEqProperties);

		if (oldUsOrgTranslate == null) {
			saveUsOrgTranslate.setId(UUID.randomUUID().toString());

			this.usOrgTranslateDao.insertByCode(saveUsOrgTranslate);

			final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(saveUsOrgTranslate);

			return this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, saveUsOrgTranslate, null, notNullIdProperties);
		}

		final String[] useProperties = EntityUtils.addNotNullTimeSegmentProperties(new String[] { CommonDtoAttributes.parentId.name(),
		        CommonDtoAttributes.typeId.name(), CommonDtoAttributes.code.name(), CommonDtoAttributes.name.name(),
		        CommonDtoAttributes.orderCode.name(), CommonDtoAttributes.value.name(), CommonDtoAttributes.remark.name() },
		        saveUsOrgTranslate);

		final String[] updateProperties = com.cardone.common.utils.BeanUtils.diffProperties(saveUsOrgTranslate, oldUsOrgTranslate,
		        useProperties);

		if (ArrayUtils.isEmpty(updateProperties)) {
			return oldUsOrgTranslate;
		}

		final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(oldUsOrgTranslate);

		com.cardone.common.utils.BeanUtils.copyProperties(oldUsOrgTranslate, saveUsOrgTranslate, notNullIdProperties);

		this.usOrgTranslateDao.updateByCode(saveUsOrgTranslate, updateProperties, notNullIdProperties);

		return this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, oldUsOrgTranslate, null, notNullIdProperties);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public UsOrgTranslateDto saveUsOrgTranslateByName(@NonNull UsOrgTranslateDto saveUsOrgTranslate) {
		final String[] whereAndEqProperties = EntityUtils.getWhereProperties(saveUsOrgTranslate, CommonDtoAttributes.code.name());

		final UsOrgTranslateDto oldUsOrgTranslate = this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, saveUsOrgTranslate,
		        null, whereAndEqProperties);

		if (oldUsOrgTranslate == null) {
			saveUsOrgTranslate.setId(UUID.randomUUID().toString());

			this.usOrgTranslateDao.insertByCode(saveUsOrgTranslate);

			final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(saveUsOrgTranslate);

			return this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, saveUsOrgTranslate, null, notNullIdProperties);
		}

		final String[] useProperties = EntityUtils.addNotNullTimeSegmentProperties(new String[] { CommonDtoAttributes.parentId.name(),
		        CommonDtoAttributes.typeId.name(), CommonDtoAttributes.code.name(), CommonDtoAttributes.name.name(),
		        CommonDtoAttributes.orderCode.name(), CommonDtoAttributes.value.name(), CommonDtoAttributes.remark.name() },
		        saveUsOrgTranslate);

		final String[] updateProperties = com.cardone.common.utils.BeanUtils.diffProperties(saveUsOrgTranslate, oldUsOrgTranslate,
		        useProperties);

		if (ArrayUtils.isEmpty(updateProperties)) {
			return oldUsOrgTranslate;
		}

		final String[] notNullIdProperties = EntityUtils.getNotNullIdProperties(oldUsOrgTranslate);

		com.cardone.common.utils.BeanUtils.copyProperties(oldUsOrgTranslate, saveUsOrgTranslate, notNullIdProperties);

		this.usOrgTranslateDao.updateByCode(saveUsOrgTranslate, updateProperties, notNullIdProperties);

		return this.usOrgTranslateDao.findByCode(UsOrgTranslateDto.class, oldUsOrgTranslate, null, notNullIdProperties);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int updateUserActivationByCode(@NonNull UserActivationDto updateUserActivation) {
		return this.userActivationDao.updateByCode(updateUserActivation, new String[] {}, new String[] {});
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int updateUserActivationByIds(@NonNull UserActivationDto updateUserActivation) {
		return this.userActivationDao.updateByIds(updateUserActivation);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int updateUserByCode(@NonNull UserDto updateUser) {
		return this.userDao.updateByCode(updateUser, new String[] {}, new String[] {});
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int updateUserByIds(@NonNull UserDto updateUser) {
		return this.userDao.updateByIds(updateUser);
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int updateUsOrgTranslateByCode(@NonNull UsOrgTranslateDto updateUsOrgTranslate) {
		return this.usOrgTranslateDao.updateByCode(updateUsOrgTranslate, new String[] {}, new String[] {});
	}

	@Override
	@Transactional
	@CacheEvict(value = UserService.BEAN_ID, allEntries = true)
	public int updateUsOrgTranslateByIds(@NonNull UsOrgTranslateDto updateUsOrgTranslate) {
		return this.usOrgTranslateDao.updateByIds(updateUsOrgTranslate);
	}
}